Skip to main content

All Questions

1vote
1answer
94views

Combinational string search using Java

I wrote a program that receives 2 strings (Input and Search) in the Search string. The sign '+' indicates that if the substring before the '+' exists in the Input string. (The search string cannot ...
HavingNoHead's user avatar
0votes
1answer
906views

Reversing the vowels in a String

Given a string, reverse only the vowels present in it and print the resulting string. Input: First line of the input file contains an integer T denoting the number of test ...
Anirudh Thatipelli's user avatar
2votes
1answer
175views

Anagram checking implementation

Given two strings, check whether two given strings are anagram of each other or not. An anagram of a string is another string that contains same characters, only the order of characters can be ...
Anirudh Thatipelli's user avatar
7votes
3answers
3kviews

Histogram of letters in string

I'm pretty new to Java and I've been trying to use top-down design and make my code very readable, so I would appreciate any comments as to the clarity and efficiency of this program. Looking for ...
Joelle Begin's user avatar
0votes
1answer
692views

Java exercise: String processing and type conversion

The exercise is from a Java-course in which I'm enrolled. The classes Book and APIResponseParser were provided by the instructor. For Book I had to add just a few getter- and setter-methods. For ...
michael.zech's user avatar
3votes
3answers
324views

Search for names in a hard-coded list of contacts

I am currently taking a class at my local community college for java programming as well as trying to learn as much as I can on my own time. I would like your opinion on a program I wrote that would ...
CakePuncher's user avatar
2votes
1answer
166views

Alternative way for checking an anagram pair

I'm writing a program to check whether a pair of Strings (entered by the user) are anagrams. I've already did with the standard way to sort both of the strings ...
hexman's user avatar
1vote
4answers
103views

Form a [email protected] address, eliminating diacritics from a name

I'm an amateur programmer who just started learning programming, my school gave me an assignment to create code that reads a surname and lastname from an input dialog box and then to edit those name ...
Semi Turdean Rajhi's user avatar
5votes
3answers
359views

Program to find unique chars in a String (and also to find number of occurences of chars in a String)

I am new to Java and learning about Strings in Java. So I wrote a program which counts the number of times a character repeats in a String and also identifies unique characters(chars not repeated more ...
LoneStar's user avatar
2votes
1answer
1kviews

Generate the alphabet and select only specific letters

I am learning java and would like to create a very simple application but which uses SOLID principles. The required functionality is: generate the alphabet with a possibility to select specific ...
kendzikq's user avatar
4votes
3answers
14kviews

Checking to see if a string is alphabetic

...
user avatar
4votes
4answers
2kviews

Check for Palindrome string in Java

I was wondering if you can give me advice on this solution to assess if an user input string is a palindrome or not. How can I optimize this solution? ...
user avatar
3votes
4answers
958views

Program to rotate an array

I wrote this code where I have to rotate an array of 'n' elements by 'd' elements in the anti-clockwise direction.Can it be done in a better and simpler way? ...
Mayank Gupta's user avatar
1vote
1answer
388views

Program for an atoi() function in Java

I have written this code to check all the edge cases in the implemention of an atoi() function.Please review. ...
Mayank Gupta's user avatar
2votes
3answers
3kviews

Program to check whether two strings are anagrams of each other

I have written this code and I am wondering if the code could be optimised.Please review. ...
Mayank Gupta's user avatar

153050per page
close